<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
      div {
        width: 100%;
        height: 100%;
        background-color: pink;
      }
      .div1 {
        /*  1vw = 1/100 * 屏幕宽度 */
        width: 50vw;
        /* 1vh = 1/100 * 屏幕高度 */
        height: 100vh;
        background-color: skyblue;
      }
    </style>
  </head>
  <body>
    <div><div class="div1">内容</div></div>
  </body>
</html>
